/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */

/*
 * ASSGui.java
 *
 * Created on Feb 16, 2012, 7:54:20 PM
 */
/**
 *
 * @author ewaisen
 */
public class ASSGui extends javax.swing.JFrame {

    /** Creates new form ASSGui */
    public ASSGui() {
        initComponents();
    }
    
    /** This method is called from within the constructor to
     * initialize the form.
     * WARNING: Do NOT modify this code. The content of this method is
     * always regenerated by the Form Editor.
     */
    @SuppressWarnings("unchecked")
    // <editor-fold defaultstate="collapsed" desc="Generated Code">//GEN-BEGIN:initComponents
    private void initComponents() {

        jScrollPane1 = new javax.swing.JScrollPane();
        outbox = new javax.swing.JTextArea();
        jScrollPane2 = new javax.swing.JScrollPane();
        inbox = new javax.swing.JTextArea();
        auto = new javax.swing.JLabel();
        send = new javax.swing.JButton();
        help = new javax.swing.JButton();

        setDefaultCloseOperation(javax.swing.WindowConstants.EXIT_ON_CLOSE);
        setTitle("Assertive Speech over Sockets Gui Chat");
        setBackground(new java.awt.Color(0, 102, 102));
        setForeground(new java.awt.Color(0, 51, 51));
        setIconImages(null);
        setResizable(false);

        jScrollPane1.setBackground(new java.awt.Color(51, 51, 51));
        jScrollPane1.setAutoscrolls(true);

        outbox.setBackground(new java.awt.Color(0, 0, 0));
        outbox.setColumns(50);
        outbox.setEditable(false);
        outbox.setFont(new java.awt.Font("Lucida Console", 0, 12)); // NOI18N
        outbox.setForeground(new java.awt.Color(0, 255, 51));
        outbox.setLineWrap(true);
        outbox.setRows(5);
        outbox.setWrapStyleWord(true);
        jScrollPane1.setViewportView(outbox);

        jScrollPane2.setBackground(new java.awt.Color(102, 102, 102));
        jScrollPane2.setAutoscrolls(true);

        inbox.setBackground(new java.awt.Color(0, 0, 0));
        inbox.setColumns(20);
        inbox.setFont(new java.awt.Font("Lucida Console", 0, 14)); // NOI18N
        inbox.setForeground(new java.awt.Color(255, 0, 255));
        inbox.setLineWrap(true);
        inbox.setRows(5);
        inbox.setWrapStyleWord(true);
        inbox.addKeyListener(new java.awt.event.KeyAdapter() {
            public void keyReleased(java.awt.event.KeyEvent evt) {
                inboxKeyReleased(evt);
            }
        });
        jScrollPane2.setViewportView(inbox);

        auto.setBackground(new java.awt.Color(0, 0, 0));
        auto.setFont(new java.awt.Font("Lucida Console", 0, 14)); // NOI18N
        auto.setForeground(new java.awt.Color(102, 0, 255));
        auto.setText("01234567890123456789");

        send.setText("Send");
        send.addMouseListener(new java.awt.event.MouseAdapter() {
            public void mouseReleased(java.awt.event.MouseEvent evt) {
                sendMouseReleased(evt);
            }
        });

        help.setText("Help");
        help.addMouseListener(new java.awt.event.MouseAdapter() {
            public void mouseReleased(java.awt.event.MouseEvent evt) {
                helpMouseReleased(evt);
            }
        });

        javax.swing.GroupLayout layout = new javax.swing.GroupLayout(getContentPane());
        getContentPane().setLayout(layout);
        layout.setHorizontalGroup(
            layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(javax.swing.GroupLayout.Alignment.TRAILING, layout.createSequentialGroup()
                .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.TRAILING)
                    .addGroup(javax.swing.GroupLayout.Alignment.LEADING, layout.createSequentialGroup()
                        .addContainerGap()
                        .addComponent(jScrollPane1, javax.swing.GroupLayout.DEFAULT_SIZE, 499, Short.MAX_VALUE))
                    .addGroup(javax.swing.GroupLayout.Alignment.LEADING, layout.createSequentialGroup()
                        .addContainerGap()
                        .addComponent(jScrollPane2, javax.swing.GroupLayout.DEFAULT_SIZE, 499, Short.MAX_VALUE))
                    .addGroup(layout.createSequentialGroup()
                        .addGap(51, 51, 51)
                        .addComponent(auto, javax.swing.GroupLayout.PREFERRED_SIZE, 265, javax.swing.GroupLayout.PREFERRED_SIZE)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED, 73, Short.MAX_VALUE)
                        .addComponent(help)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)
                        .addComponent(send)))
                .addContainerGap())
        );
        layout.setVerticalGroup(
            layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(javax.swing.GroupLayout.Alignment.TRAILING, layout.createSequentialGroup()
                .addContainerGap()
                .addComponent(jScrollPane1, javax.swing.GroupLayout.DEFAULT_SIZE, 235, Short.MAX_VALUE)
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(send)
                    .addComponent(help)
                    .addComponent(auto))
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                .addComponent(jScrollPane2, javax.swing.GroupLayout.PREFERRED_SIZE, 50, javax.swing.GroupLayout.PREFERRED_SIZE)
                .addContainerGap())
        );

        pack();
    }// </editor-fold>//GEN-END:initComponents

private void inboxKeyReleased(java.awt.event.KeyEvent evt) {//GEN-FIRST:event_inboxKeyReleased
// TODO add your handling code here:
    inbox.requestFocusInWindow();
}//GEN-LAST:event_inboxKeyReleased

private void helpMouseReleased(java.awt.event.MouseEvent evt) {//GEN-FIRST:event_helpMouseReleased
// TODO add your handling code here:
    inbox.requestFocusInWindow();
}//GEN-LAST:event_helpMouseReleased

private void sendMouseReleased(java.awt.event.MouseEvent evt) {//GEN-FIRST:event_sendMouseReleased
// TODO add your handling code here:
    inbox.requestFocusInWindow();
}//GEN-LAST:event_sendMouseReleased


    /**
     * @param args the command line arguments
     */
    public static void main(String args[]) {
        /* Set the Nimbus look and feel */
        //<editor-fold defaultstate="collapsed" desc=" Look and feel setting code (optional) ">
        /* If Nimbus (introduced in Java SE 6) is not available, stay with the default look and feel.
         * For details see http://download.oracle.com/javase/tutorial/uiswing/lookandfeel/plaf.html 
         */
        try {
            for (javax.swing.UIManager.LookAndFeelInfo info : javax.swing.UIManager.getInstalledLookAndFeels()) {
                if ("Nimbus".equals(info.getName())) {
                    javax.swing.UIManager.setLookAndFeel(info.getClassName());
                    break;
                }
            }
        } catch (ClassNotFoundException ex) {
            java.util.logging.Logger.getLogger(ASSGui.class.getName()).log(java.util.logging.Level.SEVERE, null, ex);
        } catch (InstantiationException ex) {
            java.util.logging.Logger.getLogger(ASSGui.class.getName()).log(java.util.logging.Level.SEVERE, null, ex);
        } catch (IllegalAccessException ex) {
            java.util.logging.Logger.getLogger(ASSGui.class.getName()).log(java.util.logging.Level.SEVERE, null, ex);
        } catch (javax.swing.UnsupportedLookAndFeelException ex) {
            java.util.logging.Logger.getLogger(ASSGui.class.getName()).log(java.util.logging.Level.SEVERE, null, ex);
        }
        //</editor-fold>

        /* Create and display the form */
        java.awt.EventQueue.invokeLater(new Runnable() {


            public void run() {
                new ASSGui().setVisible(true);
            }
        });
    }
    // Variables declaration - do not modify//GEN-BEGIN:variables
    private javax.swing.JLabel auto;
    private javax.swing.JButton help;
    private javax.swing.JTextArea inbox;
    private javax.swing.JScrollPane jScrollPane1;
    private javax.swing.JScrollPane jScrollPane2;
    private javax.swing.JTextArea outbox;
    private javax.swing.JButton send;
    // End of variables declaration//GEN-END:variables
}
